<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      .father {
        position: relative;
        width: 200px;
        height: 200px;
        background-color: #ccc;
      }

      .child {
        position: absolute;
        width: 80%;
        height: 80%;
        background-color: aquamarine;
      }

      .grandson {
        display: block;
        width: auto;
        height: 80%;
        background-color: #fff;
      }
    </style>
  </head>

  <body>
    <div class="father">
      <div class="child">
        <div class="grandson"></div>
      </div>
    </div>
  </body>
</html>
